package com.caishi.lkx.common.context;

import com.caishi.lkx.common.ienum.ClientType;
import com.caishi.lkx.common.ienum.DeviceType;
import com.caishi.lkx.common.ienum.PlatformType;
import lombok.*;

import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.List;

/**
 * @author by keray
 * date:2021/4/20 10:04 上午
 */
@Getter
@Setter
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class TokenData implements Serializable {
    private String userId;
    private List<String> userRole;
    private Long time;
    private DeviceType device;
    private String deviceUUID;
    // 判断用户是否有类型时使用userService.userIsHaveRole方法
    private String userTypeName;
    // 用户登录信息version version改变时用户token失效
    private String version;
    private Long groupId;
    private LocalDateTime groupTime;
    private PlatformType platformType;
    /**
     * 合法位置的机构
     * 包括ip有效
     * 地理位置有效
     */
    private Long localGroupId;

    private String infoId;

    private ClientType clientType;
    //智图的userKey
    private String ztUserKey;
}
